//
//  RESeverTableViewCell.h
//  录音
//
//  Created by ywy on 2016/12/25.
//  Copyright © 2016年 Wely. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "RETrackList.h"
#import <AVFoundation/AVFoundation.h>

typedef void(^theServerListBlock)(NSInteger tagNumber,RETrackList * listModel,BOOL isPaly,UIProgressView *progress,UITableViewCell * baseCell,NSIndexPath * indexPath);

@protocol StopPlayDelegate <NSObject>

- (void)stopPlayWithIndex:(NSIndexPath *)index withFlag:(BOOL)flag;

@end


@interface RESeverTableViewCell : UITableViewCell


@property (nonatomic, assign) id<StopPlayDelegate>delegate;

@property (nonatomic, strong) NSIndexPath *indexPath;

@property(nonatomic,assign) BOOL ispaly;
@property (nonatomic, strong) AVPlayer     *selfPlayer;
// 背景的View
@property (weak, nonatomic) IBOutlet UIView *backView;

@property (weak, nonatomic) IBOutlet UILabel *titleLabel;
// 进度条
@property (weak, nonatomic) IBOutlet UIProgressView *progress;
// 进度时间
@property (weak, nonatomic) IBOutlet UILabel *progressTime;
// 总的时间
@property (weak, nonatomic) IBOutlet UILabel *totalTimeLabel;


@property(nonatomic,strong)RETrackList*baseModel;

@property(nonatomic,copy) theServerListBlock listBloack;

@property (weak, nonatomic) IBOutlet UIButton *palyButton;

/**
    layer的界面
 */
@property (weak, nonatomic) IBOutlet UIView *layerView;

-(void)showData:(RETrackList*)model;

- (void)stopPlay;



@end
